<?php
/**
 * Created by PhpStorm.
 * User: zhanghaisheng
 * Date: 2016/11/4
 * Time: 10:21
 */



// 获取 seasons id

$redis = new \Redis();
$redis->connect('127.0.0.1',6379);

$ids = $redis->zRevRange('seasons',0,-1);



// 获取 每个 sesson
$pipeline = $redis->multi();
foreach($ids as $seasonId){
    $pipeline->hGetAll($seasonId);
}
$seasonIdS = $pipeline->exec();




//返回json数据
print_r(json_encode($seasonIdS));







